<template>
  <control-Panel
    :ismenu="false"
    @handlefullScreen="handlefullScreen"
    :fullscreen="fullscreen"
  ></control-Panel>
</template>
<script>
import controlPanel from "./controlPanel.vue";
import { nextTick, onMounted, reactive, ref } from "vue";
import { useRouter, useRoute } from "vue-router";
import { useStore } from "vuex";
export default {
components: {
  controlPanel,
},
setup() {
  const router = useRouter();
  const store = useStore();
  const route = useRoute();
  const fullscreen = ref(route.query.fullscreen || false);
  const handlefullScreen = (fullscreen) => {
    store.commit("handleCollapse", true);
    router.push("/controlPanelIndex?fullscreen=" + fullscreen);
  };
  return { fullscreen, handlefullScreen };
},
};
</script>
<style lang="less" scoped></style>
